Resource URL: /platform/<<version=1>>/auth/users/<USER>

    Overview: This resource applies the standard collection pattern to
              individual users.

     Methods: GET, PUT, DELETE

********************************************************************************

Method GET: Retrieve the user information.

       URL: GET /platform/<<version=1>>/auth/users/<USER>

Query arguments:
         cached=<boolean> If true, only return cached objects.
  resolve_names=<boolean> Resolve names of personas.
query_member_of=<boolean> Enumerate all users that a group is a member of.
            zone=<string> Filter users by zone.
        provider=<string> Filter users by provider.

GET response body schema:
{
  "type": [
    {
      "additionalProperties": false, 
      "type": "object", 
      "description": "A list of errors that may be returned.", 
      "properties": {
        "errors": {
          "items": {
            "additionalProperties": false, 
            "type": "object", 
            "description": "An object describing a single error.", 
            "properties": {
              "field": {
                "type": "string", 
                "description": "The field with the error if applicable."
              }, 
              "message": {
                "type": "string", 
                "description": "The error message."
              }, 
              "code": {
                "type": "string", 
                "description": "The error code."
              }
            }
          }, 
          "type": "array"
        }
      }
    }, 
    {
      "additionalProperties": false, 
      "type": "object", 
      "properties": {
        "users": {
          "minItems": 0, 
          "items": {
            "type": "object", 
            "description": "Specifies the configuration properties for a user.", 
            "properties": {
              "domain": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the domain that the object is part of."
              }, 
              "generated_gid": {
                "required": true, 
                "type": [
                  "boolean", 
                  "null"
                ], 
                "description": "True, if the GID was generated."
              }, 
              "on_disk_group_identity": {
                "required": true, 
                "type": [
                  {
                    "type": "object", 
                    "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                    "properties": {
                      "type": {
                        "enum": [
                          "user", 
                          "group", 
                          "wellknown"
                        ], 
                        "type": "string", 
                        "description": "Specifies the type of persona, which must be combined with a name."
                      }, 
                      "id": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                        "maxLength": 261
                      }, 
                      "name": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the persona name, which must be combined with a type.", 
                        "maxLength": 255
                      }
                    }
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the group identity on the disk."
              }, 
              "uid": {
                "required": true, 
                "type": [
                  {
                    "type": "object", 
                    "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                    "properties": {
                      "type": {
                        "enum": [
                          "user", 
                          "group", 
                          "wellknown"
                        ], 
                        "type": "string", 
                        "description": "Specifies the type of persona, which must be combined with a name."
                      }, 
                      "id": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                        "maxLength": 261
                      }, 
                      "name": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the persona name, which must be combined with a type.", 
                        "maxLength": 255
                      }
                    }
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies an ID for the user."
              }, 
              "password_expires": {
                "required": true, 
                "type": "boolean", 
                "description": "If true, the password is allowed to expire."
              }, 
              "sam_account_name": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies a user or group name."
              }, 
              "dns_domain": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the DNS domain."
              }, 
              "password_expired": {
                "required": true, 
                "type": "boolean", 
                "description": "If true, the password has expired."
              }, 
              "id": {
                "minLength": 0, 
                "required": true, 
                "type": "string", 
                "description": "Specifies the user or group ID.", 
                "maxLength": 255
              }, 
              "generated_upn": {
                "required": true, 
                "type": [
                  "boolean", 
                  "null"
                ], 
                "description": "True, if the UPN was generated."
              }, 
              "object_history": {
                "type": [
                  {
                    "type": "null"
                  }, 
                  {
                    "minItems": 0, 
                    "items": {
                      "type": "object", 
                      "properties": {
                        "gid": {
                          "type": [
                            {
                              "type": "object", 
                              "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                              "properties": {
                                "type": {
                                  "enum": [
                                    "user", 
                                    "group", 
                                    "wellknown"
                                  ], 
                                  "type": "string", 
                                  "description": "Specifies the type of persona, which must be combined with a name."
                                }, 
                                "id": {
                                  "minLength": 0, 
                                  "type": "string", 
                                  "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                                  "maxLength": 261
                                }, 
                                "name": {
                                  "minLength": 0, 
                                  "type": "string", 
                                  "description": "Specifies the persona name, which must be combined with a type.", 
                                  "maxLength": 255
                                }
                              }
                            }, 
                            "null"
                          ]
                        }, 
                        "uid": {
                          "type": [
                            {
                              "type": "object", 
                              "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                              "properties": {
                                "type": {
                                  "enum": [
                                    "user", 
                                    "group", 
                                    "wellknown"
                                  ], 
                                  "type": "string", 
                                  "description": "Specifies the type of persona, which must be combined with a name."
                                }, 
                                "id": {
                                  "minLength": 0, 
                                  "type": "string", 
                                  "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                                  "maxLength": 261
                                }, 
                                "name": {
                                  "minLength": 0, 
                                  "type": "string", 
                                  "description": "Specifies the persona name, which must be combined with a type.", 
                                  "maxLength": 255
                                }
                              }
                            }, 
                            "null"
                          ]
                        }, 
                        "sid": {
                          "type": "object", 
                          "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                          "properties": {
                            "type": {
                              "enum": [
                                "user", 
                                "group", 
                                "wellknown"
                              ], 
                              "type": "string", 
                              "description": "Specifies the type of persona, which must be combined with a name."
                            }, 
                            "id": {
                              "minLength": 0, 
                              "type": "string", 
                              "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                              "maxLength": 261
                            }, 
                            "name": {
                              "minLength": 0, 
                              "type": "string", 
                              "description": "Specifies the persona name, which must be combined with a type.", 
                              "maxLength": 255
                            }
                          }
                        }
                      }
                    }, 
                    "type": "array", 
                    "maxItems": 4294967295
                  }
                ]
              }, 
              "password_last_set": {
                "required": true, 
                "type": [
                  {
                    "minimum": 0, 
                    "type": "integer", 
                    "maximum": 4294967295
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the last time the password was set."
              }, 
              "gid": {
                "required": true, 
                "type": [
                  {
                    "type": "object", 
                    "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                    "properties": {
                      "type": {
                        "enum": [
                          "user", 
                          "group", 
                          "wellknown"
                        ], 
                        "type": "string", 
                        "description": "Specifies the type of persona, which must be combined with a name."
                      }, 
                      "id": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                        "maxLength": 261
                      }, 
                      "name": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the persona name, which must be combined with a type.", 
                        "maxLength": 255
                      }
                    }
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies a group ID for the user."
              }, 
              "provider": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the authentication provider that the object belongs to."
              }, 
              "max_password_age": {
                "required": true, 
                "type": [
                  "integer", 
                  "null"
                ], 
                "description": "Specifies the maximum time in seconds allowed before the password expires."
              }, 
              "type": {
                "minLength": 0, 
                "required": true, 
                "type": "string", 
                "description": "Specifies the object type.", 
                "maxLength": 255
              }, 
              "email": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies an email address."
              }, 
              "dn": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the distinguished name for the user."
              }, 
              "shell": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 4096
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies a path to the shell for the user."
              }, 
              "sid": {
                "required": true, 
                "type": [
                  {
                    "type": "object", 
                    "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                    "properties": {
                      "type": {
                        "enum": [
                          "user", 
                          "group", 
                          "wellknown"
                        ], 
                        "type": "string", 
                        "description": "Specifies the type of persona, which must be combined with a name."
                      }, 
                      "id": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                        "maxLength": 261
                      }, 
                      "name": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the persona name, which must be combined with a type.", 
                        "maxLength": 255
                      }
                    }
                  }
                ], 
                "description": "Specifies the security identifier."
              }, 
              "expiry": {
                "required": true, 
                "type": [
                  {
                    "minimum": 0, 
                    "type": "integer", 
                    "maximum": 4294967295
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the Unix Epoch time at which the authenticated user will expire."
              }, 
              "on_disk_user_identity": {
                "required": true, 
                "type": [
                  {
                    "type": "object", 
                    "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                    "properties": {
                      "type": {
                        "enum": [
                          "user", 
                          "group", 
                          "wellknown"
                        ], 
                        "type": "string", 
                        "description": "Specifies the type of persona, which must be combined with a name."
                      }, 
                      "id": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                        "maxLength": 261
                      }, 
                      "name": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the persona name, which must be combined with a type.", 
                        "maxLength": 255
                      }
                    }
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the user identity on the disk."
              }, 
              "password_expiry": {
                "required": true, 
                "type": [
                  {
                    "minimum": 0, 
                    "type": "integer", 
                    "maximum": 4294967295
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the time in Unix Epoch seconds that the password will expire."
              }, 
              "user_can_change_password": {
                "required": true, 
                "type": "boolean", 
                "description": "Specifies whether the password for the user can be changed."
              }, 
              "expired": {
                "required": true, 
                "type": "boolean", 
                "description": "True, if the authenticated user has expired."
              }, 
              "upn": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies a principal name for the user."
              }, 
              "locked": {
                "required": true, 
                "type": "boolean", 
                "description": "If true, indicates that the account is locked."
              }, 
              "name": {
                "minLength": 0, 
                "required": true, 
                "type": "string", 
                "description": "Specifies a user or group name.", 
                "maxLength": 255
              }, 
              "member_of": {
                "required": true, 
                "type": [
                  {
                    "type": "null"
                  }, 
                  {
                    "minItems": 0, 
                    "items": {
                      "type": "object", 
                      "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                      "properties": {
                        "type": {
                          "enum": [
                            "user", 
                            "group", 
                            "wellknown"
                          ], 
                          "type": "string", 
                          "description": "Specifies the type of persona, which must be combined with a name."
                        }, 
                        "id": {
                          "minLength": 0, 
                          "type": "string", 
                          "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                          "maxLength": 261
                        }, 
                        "name": {
                          "minLength": 0, 
                          "type": "string", 
                          "description": "Specifies the persona name, which must be combined with a type.", 
                          "maxLength": 255
                        }
                      }
                    }, 
                    "type": "array", 
                    "maxItems": 4294967295
                  }
                ], 
                "description": "Specifies the groups that this user or group are members of."
              }, 
              "enabled": {
                "required": true, 
                "type": "boolean", 
                "description": "True, if the authenticated user is enabled."
              }, 
              "primary_group_sid": {
                "required": true, 
                "type": [
                  {
                    "type": "object", 
                    "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
                    "properties": {
                      "type": {
                        "enum": [
                          "user", 
                          "group", 
                          "wellknown"
                        ], 
                        "type": "string", 
                        "description": "Specifies the type of persona, which must be combined with a name."
                      }, 
                      "id": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
                        "maxLength": 261
                      }, 
                      "name": {
                        "minLength": 0, 
                        "type": "string", 
                        "description": "Specifies the persona name, which must be combined with a type.", 
                        "maxLength": 255
                      }
                    }
                  }
                ], 
                "description": "Specifies the security ID of the primary group for the user."
              }, 
              "gecos": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 255
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies the GECOS value, which is usually the full name."
              }, 
              "generated_uid": {
                "required": true, 
                "type": [
                  "boolean", 
                  "null"
                ], 
                "description": "True, if the UID was generated."
              }, 
              "home_directory": {
                "required": true, 
                "type": [
                  {
                    "minLength": 0, 
                    "type": "string", 
                    "maxLength": 4096
                  }, 
                  {
                    "type": "null"
                  }
                ], 
                "description": "Specifies a home directory for the user."
              }, 
              "prompt_password_change": {
                "required": true, 
                "type": "boolean", 
                "description": "Prompts the user to change their password at the next login."
              }
            }
          }, 
          "type": "array", 
          "maxItems": 4294967295
        }
      }
    }
  ]
}

********************************************************************************

Method PUT: Modify the user.

       URL: PUT /platform/<<version=1>>/auth/users/<USER>

Query arguments:
  force=<boolean> Changes to the user ID can result in loss of access to the
                  file system. To mitigate this risk of lost access, the force
                  option is required for user ID changes.
    zone=<string> Optional zone.
provider=<string> Optional provider type.

PUT request body schema:
{
  "type": "object", 
  "description": "Specifies the configuration properties for a user.", 
  "properties": {
    "primary_group": {
      "type": [
        {
          "type": "object", 
          "description": "Specifies properties for a persona, which consists of either a 'type' and a 'name' or an 'ID'.", 
          "properties": {
            "type": {
              "enum": [
                "user", 
                "group", 
                "wellknown"
              ], 
              "type": "string", 
              "description": "Specifies the type of persona, which must be combined with a name."
            }, 
            "id": {
              "minLength": 0, 
              "type": "string", 
              "description": "Specifies the serialized form of a persona, which can be 'UID:0', 'USER:name', 'GID:0', 'GROUP:wheel', or 'SID:S-1-1'.", 
              "maxLength": 261
            }, 
            "name": {
              "minLength": 0, 
              "type": "string", 
              "description": "Specifies the persona name, which must be combined with a type.", 
              "maxLength": 255
            }
          }
        }
      ], 
      "description": "Specifies the primary group by name."
    }, 
    "uid": {
      "minimum": 0, 
      "type": "integer", 
      "description": "Specifies a numeric user identifier.", 
      "maximum": 4294967295
    }, 
    "password_expires": {
      "type": "boolean", 
      "description": "If true, the password should expire."
    }, 
    "sid": {
      "minLength": 0, 
      "type": "string", 
      "description": "Specifies a security identifier.", 
      "maxLength": 255
    }, 
    "enabled": {
      "type": "boolean", 
      "description": "If true, the authenticated user is enabled."
    }, 
    "expiry": {
      "minimum": 0, 
      "type": "integer", 
      "description": "Specifies the Unix Epoch time when the auth user will expire.", 
      "maximum": 4294967295
    }, 
    "unlock": {
      "type": "boolean", 
      "description": "If true, the user account should be unlocked."
    }, 
    "shell": {
      "minLength": 0, 
      "type": "string", 
      "description": "Specifies the shell for the user.", 
      "maxLength": 4096
    }, 
    "gecos": {
      "minLength": 0, 
      "type": "string", 
      "description": "Specifies the GECOS value, which is usually the full name.", 
      "maxLength": 255
    }, 
    "home_directory": {
      "minLength": 0, 
      "type": "string", 
      "description": "Specifies a home directory for the user.", 
      "maxLength": 4096
    }, 
    "password": {
      "minLength": 0, 
      "type": "string", 
      "description": "Changes the password for the user.", 
      "maxLength": 255
    }, 
    "email": {
      "minLength": 0, 
      "type": "string", 
      "description": "Specifies an email address for the user.", 
      "maxLength": 255
    }, 
    "prompt_password_change": {
      "type": "boolean", 
      "description": "If true, prompts the user to change their password at the next login."
    }
  }
}

There is no JSON response body for this method.

********************************************************************************

Method DELETE: Delete the user.

          URL: DELETE /platform/<<version=1>>/auth/users/<USER>

Query arguments:
 cached=<boolean> If true, flush the user from the cache.
    zone=<string> Filter users by zone.
provider=<string> Filter users by provider.

There is no JSON response body for this method.
